package com.dlc.shop.bean.model;

import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Data;

import java.io.Serializable;
import java.util.Date;
import java.util.List;
import java.util.Set;

/**
 * 系统访问密钥
 *
 * @author YXF
 * @date 2021-10-19 14:41:38
 */
@Data
@TableName("tz_sys_access_key")
public class SysAccessKey implements Serializable{
    private static final long serialVersionUID = 1L;

    /**
     * 主键
     */
    @TableId
    @Schema(description = "id" )
    private Long sysAccessKeyId;

    @Schema(description = "名称" )
    private String name;

    @Schema(description = "备注" )
    private String remark;

    @Schema(description = "账号id" )
    private String accessId;

    @Schema(description = "密钥" )
    private String accessKey;

    @Schema(description = "系统类型 0.c端用户 1.商家端 2.平台端" )
    private Integer sysType;

    @Schema(description = "密钥权限类型 0.全部权限 1.指定权限" )
    private Integer premType;

    @Schema(description = "密钥可用店铺id,如果为0则为所有店铺" )
    private Long usabilityShopId;

    @Schema(description = "创建时间" )
    private Date createTime;

    @Schema(description = "更新时间" )
    private Date updateTime;

    @TableField(exist=false)
    @Schema(description = "菜单id列表" )
    private List<Long> menuIdList;

    @TableField(exist=false)
    @Schema(description = "授权(多个用逗号分隔，如：user:list,user:create)" )
    private Set<String> prems;
}
